// Rect.cpp
// By Frank Luna
// August 24, 2004.

#include "..\\Includes\\Rect.h"

Rect::Rect()
{
}

Rect::Rect(const Vec2& a, const Vec2& b)
: minPt(a), maxPt(b)
{
}

Rect::Rect(float x0, float y0, float x1, float y1)
: minPt(x0, y0), maxPt(x1, y1)
{
}

bool Rect::isPtInside(const Vec2& pt)
{
	return pt.x >= minPt.x && pt.y >= minPt.y &&
		pt.x <= maxPt.x && pt.y <= maxPt.y;
}